package top.dark.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import top.dark.common.utils.PageUtils;
import top.dark.product.entity.AttrEntity;
import top.dark.product.entity.ProductAttrValueEntity;
import top.dark.product.vo.AttrGroupRelationVo;
import top.dark.product.vo.AttrRespVo;
import top.dark.product.vo.AttrVo;

import java.util.List;
import java.util.Map;

/**
 * 商品属性
 *
 * @author lijiao
 * @email DarknessShadow11@outlook.com
 * @date 2021-02-01 10:42:11
 */
public interface AttrService extends IService<AttrEntity> {

    PageUtils queryPage(Map<String, Object> params);

    void saveAttr(AttrVo attr);

    PageUtils baseAttrListPage(Map<String, Object> params, Long catId,String attrType);

    AttrRespVo getAttrInfo(Long attrId);

    void updateAttr(AttrVo attr);

    List<AttrEntity> attrRelation(Long attrgroupId);

    void batchDeleteRelation(AttrGroupRelationVo[] vos);

    PageUtils getNoattrRelation(Long attrgroupId, Map<String, Object> params);

    List<Long> listByIdsAndSearchType(List<Long> ids);

    List<ProductAttrValueEntity> listAttrsforspu(Long spuId);
}

